<template>
	<view class="content">
		<view class="time">
			{{time}}s
		</view>
		<image class="logo" 
			   :src="this.util.get_img_url(gConfig.home_site_logo_wap)">
		</image>
		<view class="text-area">
			<text class="title">{{gConfig.home_site_name}}</text>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				gConfig:{},
				time:3
			}
		},
		onLoad() {
			var self=this;
			//设置倒计时
			var timer=setInterval(function(){
				self.time--;
			},1000)
			
			// 取出全局配置信息
			this.gConfig=uni.getStorageSync("gConfig");
			// 设置定时器跳转
			setTimeout(function(){
				clearInterval(timer);
				uni.switchTab({
					url: '/pages/index/index'
				});
			},3000);
			
		},
		methods: {

		}
	}
</script>

<style>
	.content {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
	}
	.time{
		border-radius: 20px;
		width:60rpx;
		height:26rpx;
		text-align: center;
		line-height: 26rpx;
		color: #555555;
		border:solid 1px #555555;
		float: right;
		margin: 50rpx 20px 0 0;
		font-size: 22rpx;
		align-self: flex-end;
		}
	.logo {
		height: 200rpx;
		width: 200rpx;
		margin-top: 260rpx;
		margin-left: auto;
		margin-right: auto;
		margin-bottom: 50rpx;
	}

	.text-area {
		display: flex;
		justify-content: center;
	}

	.title {
		font-size: 80rpx;
		color: $uni-text-color-zhu;
		font-weight: bold;
	}
</style>

